package com.ocean.service.library;

import com.ocean.entity.library.Book;
import com.ocean.vo.R;
import org.springframework.stereotype.Service;
import org.springframework.web.multipart.MultipartFile;

import javax.servlet.http.HttpServletResponse;
import java.io.IOException;
import java.util.List;

/**
 * Project：SchoolManage
 * Package：com.ocean.service.library.impl
 * Author:zy
 * Time:2023/3/3
 */

public interface BookService {
    /**
     * 新增图书
     * @param book
     * @return
     */
    R save(Book book);

    /**
     * 分页查询
     * @return
     */
    R queryPage(int page, int size,String name,String author);

    R delete(int id);

    R update(Book book);

    R selectIdByName(String name);

    R importData(MultipartFile file) throws IOException;

    void exportData(HttpServletResponse response) throws IOException;

    R queryEcharts();
}
